115 research outputs found

    ToolkenGPT: Augmenting Frozen Language Models with Massive Tools via Tool Embeddings

    Full text link
    Augmenting large language models (LLMs) with external tools has emerged as a promising approach to solving complex problems. However, traditional methods, which finetune LLMs with tool demonstration data, can be both costly and restricted to a predefined set of tools. Recent in-context learning paradigm alleviates these issues, but the limited context length only allows for a few shots of demonstrations, leading to suboptimal understandings of the tools. Moreover, when there are numerous tools to choose from, in-context learning could completely fail to work. In this paper, we propose an alternative approach, ToolkenGPT\textbf{ToolkenGPT}, which combines the benefits of both sides. Our approach represents each tool\underline{tool} as a token\underline{ken} (toolken\textit{toolken}) and learns an embedding for it, enabling tool calls in the same way as generating a regular word token. Once a toolken is triggered, the LLM is prompted to complete arguments for the tool to execute. ToolkenGPT offers the flexibility to plug in an arbitrary number of tools by expanding the set of toolkens on the fly. In addition, it improves tool use by allowing extensive demonstration data for learning the toolken embeddings. In diverse domains, including numerical reasoning, knowledge-based question answering, and embodied plan generation, our approach effectively augments LLMs with tools and substantially outperforms various latest baselines. ToolkenGPT demonstrates the promising ability to use relevant tools from a large tool set in complex scenarios

    Hit Ratio Driven Mobile Edge Caching Scheme for Video on Demand Services

    Full text link
    More and more scholars focus on mobile edge computing (MEC) technology, because the strong storage and computing capabilities of MEC servers can reduce the long transmission delay, bandwidth waste, energy consumption, and privacy leaks in the data transmission process. In this paper, we study the cache placement problem to determine how to cache videos and which videos to be cached in a mobile edge computing system. First, we derive the video request probability by taking into account video popularity, user preference and the characteristic of video representations. Second, based on the acquired request probability, we formulate a cache placement problem with the objective to maximize the cache hit ratio subject to the storage capacity constraints. Finally, in order to solve the formulated problem, we transform it into a grouping knapsack problem and develop a dynamic programming algorithm to obtain the optimal caching strategy. Simulation results show that the proposed algorithm can greatly improve the cache hit ratio

    Reasoning with Language Model is Planning with World Model

    Full text link
    Large language models (LLMs) have shown remarkable reasoning capabilities, especially when prompted to generate intermediate reasoning steps (e.g., Chain-of-Thought, CoT). However, LLMs can still struggle with problems that are easy for humans, such as generating action plans for executing tasks in a given environment, or performing complex math, logical, and commonsense reasoning. The deficiency stems from the key fact that LLMs lack an internal world model\textit{world model} to predict the world state\textit{state} (e.g., environment status, intermediate variable values) and simulate long-term outcomes of actions. This prevents LLMs from performing deliberate planning akin to human brains, which involves exploring alternative reasoning paths, anticipating future states and rewards, and iteratively refining existing reasoning steps. To overcome the limitations, we propose a new LLM reasoning framework, Reasoning viaPlanning\underline{R}\textit{easoning vi}\underline{a} \underline{P}\textit{lanning} (RAP)\textbf{(RAP)}. RAP repurposes the LLM as both a world model and a reasoning agent, and incorporates a principled planning algorithm (based on Monto Carlo Tree Search) for strategic exploration in the vast reasoning space. During reasoning, the LLM (as agent) incrementally builds a reasoning tree under the guidance of the LLM (as world model) and task-specific rewards, and obtains a high-reward reasoning path efficiently with a proper balance between exploration vs.\textit{vs.} exploitation. We apply RAP to a variety of challenging reasoning problems including plan generation, math reasoning, and logical inference. Empirical results on these tasks demonstrate the superiority of RAP over various strong baselines, including CoT and least-to-most prompting with self-consistency. RAP on LLAMA-33B surpasses CoT on GPT-4 with 33% relative improvement in a plan generation setting

    BertNet: Harvesting Knowledge Graphs with Arbitrary Relations from Pretrained Language Models

    Full text link
    It is crucial to automatically construct knowledge graphs (KGs) of diverse new relations to support knowledge discovery and broad applications. Previous KG construction methods, based on either crowdsourcing or text mining, are often limited to a small predefined set of relations due to manual cost or restrictions in text corpus. Recent research proposed to use pretrained language models (LMs) as implicit knowledge bases that accept knowledge queries with prompts. Yet, the implicit knowledge lacks many desirable properties of a full-scale symbolic KG, such as easy access, navigation, editing, and quality assurance. In this paper, we propose a new approach of harvesting massive KGs of arbitrary relations from pretrained LMs. With minimal input of a relation definition (a prompt and a few shot of example entity pairs), the approach efficiently searches in the vast entity pair space to extract diverse accurate knowledge of the desired relation. We develop an effective search-and-rescore mechanism for improved efficiency and accuracy. We deploy the approach to harvest KGs of over 400 new relations from different LMs. Extensive human and automatic evaluations show our approach manages to extract diverse accurate knowledge, including tuples of complex relations (e.g., "A is capable of but not good at B"). The resulting KGs as a symbolic interpretation of the source LMs also reveal new insights into the LMs' knowledge capacities.Comment: ACL 2023 (Findings); Code available at https://github.com/tanyuqian/knowledge-harvest-from-lm

    Microstructures, Mechanical Properties and Transformation Behavior in Ni49.6Ti35.4Hf15 Alloy Produced with High-Pressure Torsion

    Get PDF
    High-pressure torsion (HPT) was applied for the Ni49.6Ti35.4Hf15 (at.%) alloy up to 1/4, 2 and 16 turns under a pressure of 4.0 GPa. The samples were examined using X-ray diffraction (XRD), transmission electron microscope (TEM) and microhardness measurements. The results indicate that the mixture of an amorphous and nanocrystalline microstructure developed in the investigated NiTiHf alloy as the number of HPT turns was increased to two. The average hardness of the samples increased from 330 Hv to 500 Hv after 16 turns of HPT. Very fine martensite developed when the HPT-processed samples were annealed at 550 ⁰C and the finer microstructures were attained with higher HPT turns. Differential scanning calorimetry (DSC) tests were performed in the post-HPT annealing samples to clarify the transformation behavior after severe plastic deformation in HPT and subsequent annealing, so as to provide an experimental basis for the application of the shape memory alloy. The transformation temperature of the alloy decreased remarkably when the number of turns of HPT reached 16. It is suggested that the deformation extent and annealing temperatures should be considered in order to maintain a high transformation temperature while utilizing the strengthening effect of HPT in the NiTiHf alloy

    Expression of HPV16 E5 Produces Enlarged Nuclei and Polyploidy through Endoreplication

    Get PDF
    Anogenital cancers and head and neck cancers are causally-associated with infection by high-risk human papillomavirus (HPV). The mechanism by which high-risk HPVs contribute to oncogenesis is poorly understood. HPV16 encodes three genes (HPV16 E5, E6, and E7) that can transform cells when expressed independently. HPV16 E6 and E7 have well-described roles causing genomic instability and unregulated cell cycle progression. The role of HPV16 E5 in cell transformation remains to be elucidated. Expression of HPV16 E5 results in enlarged, polyploid nuclei that are dependent on the level and duration of HPV16 E5 expression. Live-cell imaging data indicate these changes do not arise from cell-cell fusion or failed cytokinesis. The increase in nuclear size is a continual process that requires DNA synthesis. We conclude HPV16 E5 produces polyploid cells by endoreplication. These findings provide insight into how HPV16 E5 can contribute to cell transformation
    corecore